SCREEN _NEWIMAGE(128, 128,14)

 sub PUTSTRING(s$, x%, y%)
  '   ⎺⎺⎺⎺⎺⎺⎺⎺⎺
  for c = 1 to len(s$)
	  sc$ = MID$(s$, c, 1)
    this$ = _GETCHR$(ASC(sc$))
    for yi = 0 to 7
      for xi = 0 to 7
        IF MID$(this$, (xi + yi*8) + 1, 1) = "X" THEN PSET (x% + xi + (c-1)*8, y% + yi)
      next xi
    next yi
  next c
  end sub

_LETCHR$(0, "........" + "........" + "...XX..." + "..XXXX.." + "..XXXX.." + "...XX..." + "........" + "........" )
_LETCHR$(1, "........" + "........" + "........" + "...XX..." + "...XX..." + "........" + "........" + "........" )
_LETCHR$(2, STRING$(64, "X"))
DiceBack$ = STRING$(3,CHR$(2))

DO
    FOR val% = 1 TO 6
        x% = 5 : y% = 5
        COLOR 63 : GOSUB 🔲SetDieFrame
        COLOR  1 : GOSUB ⭕SetPitEdges
        COLOR  3 : GOSUB 🔴SetPits
        _DELAY 1
    NEXT val%
LOOP
END

🔲SetDieFrame:
      PutString( DiceBack$, x%, y%)
      PutString( DiceBack$, x%, y% + 8)
      PutString( DiceBack$, x%, y% + 16)
  RETURN

FUNCTION Line1$(c%)
      temp$ = ""
      IF val% > 3 then temp$ = CHR$(c%) ELSE temp$ = " "
      IF val% > 1 then temp$ = temp$ + " " + CHR$(c%)
      Line1$ = temp$
  END FUNCTION

FUNCTION Line2$(c%)
      temp$ = ""
      IF val% mod 2 = 1 THEN temp$ = " " + CHR$(c%) + " " 
      IF val% = 6 THEN temp$ = CHR$(c%) + " " + CHR$(c%)
      Line2$ = temp$
  END FUNCTION

FUNCTION Line3$(c%)
      temp$ = ""
      IF val% > 1 THEN temp$ = CHR$(c%) ELSE temp$ = " "
      IF val% > 3 THEN temp$ =  temp$ + " " + CHR$(c%)
      Line3$ = temp$
  END FUNCTION

⭕SetPitEdges:
      PutString( Line1$(0), x%, y%)
      PutString( Line2$(0), x%, y% + 8)
      PutString( Line3$(0), x%, y% + 16)
  RETURN

🔴SetPits:
      PutString( Line1$(1), x%, y%)
      PutString( Line2$(1), x%, y% + 8)
      PutString( Line3$(1), x%, y% + 16)
  RETURN